<ul id="${id}" name="${id}" style="padding: 0;width: 100%;font-size: 16px">
    @for(item in list){
    <div style="display: none">
        <p style="background-color: palegreen;font-weight: bold;padding-left: 10px"
           value="${item.getTime}">${item.getTime}</p>
    </div>
    <li value="${item.customerId}"
        style="box-shadow: 2px 2px 3px #888888;border-bottom: 10px solid #5cdfc0;position: relative;background:white;padding:10px 0 0 30px;margin-top: 30px;">
        <p style="font-weight: bold;font-size: 28px;line-height: 40px;color: #5cdfc0;"
           value="${item.operationTime}">${item.operationTimeOne}</p>
        <p style="font-weight: bold;font-size: 22px;color: #5cdfc0;"
           value="${item.operationTime}">${item.operationTimeTwo}</p>
        <div value="${item.operationTime}" style="padding-bottom: 20px;overflow: hidden;"></div>
    </li>
    <script>
        $.ajax({
            url: Feng.ctxPath + "/consultant/getOpenBillList",
            type: "post",
            data: {
                "operationTime": $("p[value='${item.operationTime}']").text(),
                "customerId": $("#customerId").val(),
                "getTime": $("p[value='${item.getTime}']").text(),
                "reservationsId": $("#reservationsId").val()
            },
            success: function (data) {
                console.log(data);
                var s1 = '';
                var ss = "";
                var sss = "";
                var doctors="";
                for (var i = 0; i < data.length; i++) {
                    var serviceapay=data[i].foldingPay-data[i].arrears;
                    ss += ' <div class="data_row" style="margin-top: 5px;" >' +
                        '                <div style=\"padding-left: 10px;width: 120px;display: inline-block;position: relative;top: 11px;\">\n' +
                        '                    <div style=\"border-bottom: 1px solid;\">\n' +
                        '                        <div style=\"font-size: 12px;display: inline-block;width:55px;border-right: 1px solid black;text-align: right;height: 22px;margin-bottom: -5px;\" id=\"yw_left_top\">' + data[i].leftUp + '</div><!--\n' +
                        '                         --><div style=\"font-size: 12px;display: inline-block;width:55px;\" id=\"yw_right_top\">' + data[i].rightUp + '</div>\n' +
                        '                   </div>\n' +
                        '                    <div>\n' +
                        '                        <div style=\"font-size: 12px;display: inline-block;width:55px;border-right: 1px solid black;text-align: right;height: 22px;margin-bottom: -5px;\" id=\"yw_left_bottom\">' + data[i].leftDown + '</div><!--\n' +
                        '                         --><div style=\"font-size: 12px;display: inline-block;width:55px;\" id=\"yw_right_bottom\">' + data[i].rightDown + '</div>\n' +
                        '                   </div>\n' +
                        '                </div>\n' +
                        '<span>&nbsp'+ data[i].payServiceName+'</span> X <span>'+data[i].payServiceNum+'</span>'+
                        '<p style="margin-top: 20px;"><span id="y_' + data[i].id2 + '" style="display: inline-block;width: 21%;">医生：' + data[i].doctor + '</span>' +
                        '<span id="h_' + data[i].id2 + '" style="display: inline-block;width: 21%;">护士：' + data[i].nurse + '</span>' +
                        '<a href="javascript:;" style="color: #da6792;" onclick=\'modify_ys("' + data[i].customerId + '","' + data[i].id2 + '","' + data[i].reservationsId + '","' + data[i].operationTime + '")\'>修改</a></p>'+
                        '<p><span style="display: inline-block;width: 21%;">折后价：' + data[i].foldingPay + '</span>' +
                        '<span style="display: inline-block;width: 13%;">实收：' + data[i].serviceActualPay + '</span>'+
                        '<span>欠款：' + data[i].arrears + '</span></p>'+
                        '</div>';
                    sss += ' <div class="data_row" style="margin-bottom: 10px">' +
                         data[i].department + '&nbsp&nbsp' + data[i].firstLevelProject + '&nbsp&nbsp </div>';
                }
                if ((data[data.length - 1].dealStatus) == "已开单" && (data[data.length - 1].reservationsId) == $("#reservationsId").val()) {
                    s1 += '<p style="font-weight: bold;color: #666666;margin:10px 0 0;"><span>咨询师：' + data[data.length - 1].tcName + '</span></p>' +
                        '<div style="position: absolute;right: 8%;bottom: 10%;"><p style="font-weight: bold;font-size: 35px;color: #31add1"><span style="font-size: 18px;margin-left: 5px;color:#4f4f4f;">总实收</span>' + data[data.length - 1].totleServiceActualPay + '<span style="font-size: 18px;margin-left: 5px;">元</span></p>' +
                        '<p style="font-weight: bold;font-size: 18px;margin-left: 15%">欠款 ' + data[data.length - 1].accountArrears + '元</p></div>'+
                        '<span  style="padding: 4px 18px;background:#5cdfc0;position: absolute;top: 7%;left: 29%;color: white;border-radius: 5px;">' + data[data.length - 1].dealStatus + '</span>'+
                        '<span style="position: absolute;top: 8%;right: 46%">【' + data[data.length - 1].outpatientName + '】</span>'+
                        '<a href="javascript:;" style="position: absolute;top: 8%;right: 39%;color: #da6792;" onclick=\'toVoid("' + data[data.length - 1].customerId + '","' + data[data.length - 1].reservationsId + '","' + data[data.length - 1].operationTime + '")\'>作废</a>' +
                        '<a href="javascript:;" style="position: absolute;top: 8%;right: 26%;color: #da6792;" onclick=\'singlePrint("' + data[data.length - 1].customerId + '","' + data[data.length - 1].reservationsId + '","' + data[data.length - 1].operationTime + '")\'>打印确认单</a>';
                    doctors += '<div><span style="font-weight: bold;color: #666666;">备注：</span><span>' + data[data.length - 1].remarks + '</span></div>'
                    $("div[value='${item.operationTime}']").html(s1 + ss + doctors);
                } else if ((data[data.length - 1].dealStatus) == "已成交" && (data[data.length - 1].reservationsId) == $("#reservationsId").val()) {
                    s1 += '<p style="font-weight: bold;color: #666666;margin:10px 0 0;""><span>咨询师：' + data[data.length - 1].tcName + '</span></p>' +
                        '<div style="position: absolute;right: 4%;bottom: 7%;"><p style="font-weight: bold;font-size: 35px;color: #31add1"><span style="font-size: 18px;margin-left: 5px;color:#4f4f4f;">总实收</span>' + data[data.length - 1].totleServiceActualPay + '<span style="font-size: 18px;margin-left: 5px;">元</span></p>' +
                        '<p style="font-weight: bold;font-size: 18px;margin-left: 15%">欠款 ' + data[data.length - 1].accountArrears + '元</p></div>'+
                        '<span  style="padding: 4px 18px;background:#5cdfc0;position: absolute;top: 7%;left: 29%;color: white;border-radius: 5px;">' + data[data.length - 1].dealStatus + '</span>'+
                        '<span style="position: absolute;top: 8%;right: 46%">【' + data[data.length - 1].outpatientName + '】</span>'+
                        '<span style="position: absolute;top: 8%;right: 37%;color: #d86993;" onclick=\'payQianKuan("' + data[data.length - 1].customerId + '","' + data[data.length - 1].reservationsId + '","' + data[data.length - 1].operationTime +'")\'>补欠款</span>'+
                        '<a href="javascript:;" style="position: absolute;top: 8%;right: 30%;color: #da6792;" onclick=\'refundMoney("' + data[data.length - 1].customerId + '","' + data[data.length - 1].reservationsId + '","' + data[data.length - 1].operationTime + '")\'>退款</a>';
                    doctors += '<div><span style="font-weight: bold;color: #666666;">备注：</span><span>' + data[data.length - 1].remarks + '</span></div>';
                    $("div[value='${item.operationTime}']").html(s1 + ss + doctors);
                } else if ((data[data.length - 1].dealStatus) == "未成交" && (data[data.length - 1].reservationsId) == $("#reservationsId").val()) {
                    s1 += '<span  style="padding: 4px 18px;background:#5cdfc0;position: absolute;top: 7%;left: 32%;color: white;border-radius: 5px;">' + data[data.length - 1].dealStatus + '</span>';
                    doctors += '原因：' + data[data.length - 1].noDealCause + data[data.length - 1].dealStatus + '</div>';
                    $("div[value='${item.operationTime}']").html(s1 + sss +doctors);
                } else if ((data[data.length - 1].dealStatus) == "作废" && (data[data.length - 1].reservationsId) == $("#reservationsId").val()) {
                    s1 += '<span  style="padding: 4px 18px;background:#5cdfc0;position: absolute;top: 7%;left: 32%;color: white;border-radius: 5px;">' + data[data.length - 1].dealStatus + '</span>';
                    doctors += '原因：' + data[data.length - 1].toVoidCause + '</div>';
                    $("div[value='${item.operationTime}']").html(s1 + ss +doctors);
                }
            },
            error: function (data) {
                alert('内部故障!');
            }
        });
    </script>
    @}
</ul>
@if(isNotEmpty(underline) && underline == 'true'){
<div class="hr-line-dashed"></div>
@}


